var gr = ctx.get_web().get_siteGroups();
ctx.load(gr)
ctx.executeQueryAsync()

en = gr.getEnumerator()
///
en.moveNext()
g = en.get_current()
g.get_title()
"Members"
////
en.moveNext()
g = en.get_current()
g.get_title()
"Owners"
///
owners = g
u = ctx.get_web().get_currentUser()
uc = owners.get_users()
uc.addUser(u)
ctx.load(u)
ctx.load(owners)
ctx.executeQueryAsync()